<%@ page contentType="text/html;charset=UTF-8" language="java"%>
<%@include file="/common.jsp"%>
<!DOCTYPE html>
<html lang="zh">
<meta charset="utf-8">
<head></head>
<body class="gray-bg">
	<div class="container-div">
		<div class="row">
			<div class="btn-group-sm hidden-xs" id="toolbar" role="group">
				纳税人[${taxpayerName }] 的信息：
				<a class="btn btn-success"
					onclick="window.location.href = '${ctx}/system/ledger/list?taxpayerName=${taxpayerName }&ledgerTaxpayer=${taxpayerId }'">
					<i class="fa fa-calendar-check-o"></i>
					总账
				</a>
				<a class="btn btn-success"
					onclick="window.location.href = '${ctx}/system/ledger/listmodel?taxpayerName=${taxpayerName }&taxpayerId=${taxpayerId }'">
					<i class="fa fa-address-card-o"></i>
					明细账
				</a>
			</div>
			<div class="col-sm-12 select-table table-striped">
				<table id="bootstrap-table" data-mobile-responsive="true"></table>
			</div>
		</div>
	</div>
	<script th:inline="javascript">
		var prefix = "${ctx}/system/ledger";
	
		$(function() {
			var options = {
				url : prefix + "/listday?taxpayerId=${taxpayerId}",
				createUrl : prefix + "/add",
				updateUrl : prefix + "/edit/{id}",
				removeUrl : prefix + "/remove",
				exportUrl : prefix + "/export",
				modalName : "账薄",
				search : false,
				showExport : true,
				showColumns : false,
				showToggle : false,
				columns : [ {
					checkbox : true
				},
					{
						field : 'ledgerTime',
						title : '时间'
					},
	
					{
						field : 'ledgerDebit',
						title : '借记',
					},
					{
						field : 'ledgerRedit',
						title : '贷记',
					},
	
				/* 	{
						title : '操作',
						align : 'center',
						formatter : function(value, row, index) {
							var actions = [];
							actions.push('<a class="btn btn-success btn-xs" href="#" onclick="$.operate.edit(\'' + row.ledgerId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
							actions.push('<a class="btn btn-danger btn-xs" href="#" onclick="$.operate.remove(\'' + row.ledgerId + '\')"><i class="fa fa-remove"></i>删除</a>');
							return actions.join('');
						}
					} */
				]
			};
			$.table.init(options);
		});
	</script>
</body>
</html>